package com.oocl.homework.format.moel;

import com.oocl.homework.verify.Verify;

public class Customer {
	
	
	@Verify(pattern="\\d+")
	private String id;
	@Verify(pattern="[a-zA-Z]+")
	private String name;
	@Verify(pattern="\\w[-\\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\\.)+[A-Za-z]{2,14}")
	private String email;
	@Verify(pattern="(true)|(false)")
	private String sex;
	@Verify(pattern="((19\\d{2})|((200[0-1])|(201[{0-7])))-(([1-9])|(0[1-9])|(1[0-2]))-(([1-2][0-9])|([1-9])|(0[1-9])|(3[0-1]))")
	private String birthday;
	
	
	public void setId(String id) {
		this.id = id;
	}
	
	public String getId() {
		return id;
	}

	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getEmail() {
		return email;
	}
	public void setEmail(String email) {
		this.email = email;
	}
	public String getSex() {
		return sex;
	}
	public void setSex(String sex) {
		this.sex = sex;
	}
	public String getBirthday() {
		return birthday;
	}
	public void setBirthday(String birthday) {
		this.birthday = birthday;
	}

	@Override
	public String toString() {
		return "Customer [id=" + id + ", name=" + name + ", email=" + email
				+ ", sex=" + sex + ", birthday=" + birthday + "]";
	}
	
	
	

}
